Optimal. Leaf size=62 \[ \frac{A \tan ^3(e+f x)}{3 a^2 c^2 f}+\frac{A \tan (e+f x)}{a^2 c^2 f}+\frac{B \sec ^3(e+f x)}{3 a^2 c^2 f} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.139538, antiderivative size = 62, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 36, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.083, Rules used = {2967, 2669, 3767} \[ \frac{A \tan ^3(e+f x)}{3 a^2 c^2 f}+\frac{A \tan (e+f x)}{a^2 c^2 f}+\frac{B \sec ^3(e+f x)}{3 a^2 c^2 f} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2967
Rule 2669
Rule 3767
Rubi steps
\begin{align*} \int \frac{A+B \sin (e+f x)}{(a+a \sin (e+f x))^2 (c-c \sin (e+f x))^2} \, dx &=\frac{\int \sec ^4(e+f x) (A+B \sin (e+f x)) \, dx}{a^2 c^2}\\ &=\frac{B \sec ^3(e+f x)}{3 a^2 c^2 f}+\frac{A \int \sec ^4(e+f x) \, dx}{a^2 c^2}\\ &=\frac{B \sec ^3(e+f x)}{3 a^2 c^2 f}-\frac{A \operatorname{Subst}\left (\int \left (1+x^2\right ) \, dx,x,-\tan (e+f x)\right )}{a^2 c^2 f}\\ &=\frac{B \sec ^3(e+f x)}{3 a^2 c^2 f}+\frac{A \tan (e+f x)}{a^2 c^2 f}+\frac{A \tan ^3(e+f x)}{3 a^2 c^2 f}\\ \end{align*}
Mathematica [A] time = 0.118258, size = 53, normalized size = 0.85 \[ \frac{A \left (\frac{1}{3} \tan ^3(e+f x)+\tan (e+f x)\right )}{a^2 c^2 f}+\frac{B \sec ^3(e+f x)}{3 a^2 c^2 f} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.066, size = 145, normalized size = 2.3 \begin{align*} 2\,{\frac{1}{f{c}^{2}{a}^{2}} \left ( -1/3\,{\frac{A/2+B/2}{ \left ( \tan \left ( 1/2\,fx+e/2 \right ) -1 \right ) ^{3}}}-1/2\,{\frac{A/2+B/2}{ \left ( \tan \left ( 1/2\,fx+e/2 \right ) -1 \right ) ^{2}}}-{\frac{A/2+B/4}{\tan \left ( 1/2\,fx+e/2 \right ) -1}}-1/2\,{\frac{-A/2+B/2}{ \left ( \tan \left ( 1/2\,fx+e/2 \right ) +1 \right ) ^{2}}}-1/3\,{\frac{A/2-B/2}{ \left ( \tan \left ( 1/2\,fx+e/2 \right ) +1 \right ) ^{3}}}-{\frac{A/2-B/4}{\tan \left ( 1/2\,fx+e/2 \right ) +1}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 0.987443, size = 63, normalized size = 1.02 \begin{align*} \frac{\frac{{\left (\tan \left (f x + e\right )^{3} + 3 \, \tan \left (f x + e\right )\right )} A}{a^{2} c^{2}} + \frac{B}{a^{2} c^{2} \cos \left (f x + e\right )^{3}}}{3 \, f} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.61172, size = 103, normalized size = 1.66 \begin{align*} \frac{{\left (2 \, A \cos \left (f x + e\right )^{2} + A\right )} \sin \left (f x + e\right ) + B}{3 \, a^{2} c^{2} f \cos \left (f x + e\right )^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 17.455, size = 651, normalized size = 10.5 \begin{align*} \text{result too large to display} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.19815, size = 117, normalized size = 1.89 \begin{align*} -\frac{2 \,{\left (3 \, A \tan \left (\frac{1}{2} \, f x + \frac{1}{2} \, e\right )^{5} + 3 \, B \tan \left (\frac{1}{2} \, f x + \frac{1}{2} \, e\right )^{4} - 2 \, A \tan \left (\frac{1}{2} \, f x + \frac{1}{2} \, e\right )^{3} + 3 \, A \tan \left (\frac{1}{2} \, f x + \frac{1}{2} \, e\right ) + B\right )}}{3 \,{\left (\tan \left (\frac{1}{2} \, f x + \frac{1}{2} \, e\right )^{2} - 1\right )}^{3} a^{2} c^{2} f} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]